FIX: Fixes dynamic property deprecation error#6193
FIX: Fixes dynamic property deprecation error#6193zanderwar wants to merge 1 commit intobcit-ci:developfrom
Conversation
|
I think a better way is to implement #[\AllowDynamicProperties] /system/core/URI.php /system/core/Router.php /system/core/Loader.php /system/core/Controller.php /system/core/DB_driver.php |
Thanks, but thats a bit of a hack for lazy people. IDE auto-completion would be more grateful for the explicit declaration of the properties on the class; so will developers... If that's the route the maintainers want to take then thats up to their discretion, personally never used codeigniter 👍 |
Thanks a lot. |
|
right.so you can use Trait without change core like this #[\AllowDynamicProperties]
class MY_URI extends CI_URI {}and application/core/MY_Router.php: #[\AllowDynamicProperties]
class MY_Router extends CI_Router {}and another classes $config['subclass_prefix'] = 'MY_'; |
Closes #6192
Let me know if you would prefer a scope other than
public(asMock_Core_URIneeds access to it, I'm assumingpublicis fine.)